/*
 * MODULE NAME:    pal_event_gen.h
 * DESCRIPTION:    PAL Implementation 
 * AUTHOR:         Tianwq
 *
 *
 * LICENSE:
 *     This source code is copyright (c) 2000-2002 RDA Microelectronics.
 *     All rights reserved.
 *
 */
#ifndef _RDABT_PAL_EVENT_H_
#define _RDABT_PAL_EVENT_H_


typedef struct st_pal_event_info
{
    t_api status;
    u_int8  mode;
    u_int8 number;
    u_int8  role;
    u_int8 key_type;
    u_int16 handle;
    u_int16 value16bit;
    u_int16 rx_packet_length;
    u_int16 tx_packet_length;
    u_int32 latency;
    u_int32 token_rate;
    t_bdaddr* p_bd_addr;
    const u_int8* p_u_int8;
    u_int8 ack_required;

} t_pal_event_info;


typedef struct 
{
    u_int8 transport;
    u_int16 opcode;
    u_int16 handle;
    u_int8 mode;
    const u_int8* p_u_int8;
    t_api  status;
    const t_bdaddr* p_bd_addr;
    u_int16 value16bit;
    u_int8 number;
} t_pal_cmd_complete_event;


t_api PAL_Set_Event_Mask(u_int8 *p_pdu);

t_api PAL_Inquiry_Result_Event(u_int8 event_code, t_pal_event_info* p_inq_event_info);
void PAL_Command_Complete_Event(t_pal_cmd_complete_event* event_info);
void PAL_Command_Status_Event(t_api  status, u_int16 opcode);
t_api PAL_Generate_Event(u_int8 event_code,t_pal_event_info* p_event_info);

#endif
 
